/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 刘国水
 * Date: 2025-04-19
 * Time: 13:13
 */
public class test {
    public static void main(String[] args) {
        MyList myList = new MyList();
        myList.addLast(11);
        myList.addLast(22);
        myList.addLast(33);
        myList.addLast(44);
        myList.addLast(55);
        myList.addIndex(0,1);
        myList.display();
    }
    public static void main7(String[] args) {
        MyList myList = new MyList();
        myList.addLast(11);
        myList.addLast(22);
        myList.addLast(33);
        myList.addLast(44);
        myList.addLast(55);
        myList.addIndex(3,0);
        myList.display();
        System.out.println("==============");
//        myList.removeAllKey(11);
//        myList.display();
    }
    public static void main6(String[] args) {
        MyList myList = new MyList();
        myList.addLast(11);
        myList.addLast(22);
        myList.addLast(33);
        myList.addLast(44);
        myList.addLast(55);
        myList.display();
        System.out.println("============");
        myList.remove(0);
        myList.display();

    }
    public static void main5(String[] args) {
        MyList myList =new MyList();
        myList.remove(11);
    }
    public static void main4(String[] args) {
        MyList myList = new MyList();
        myList.addLast(11);
        myList.addLast(22);
        myList.addLast(33);
        myList.addLast(44);
        myList.addLast(55);
        myList.display();
        System.out.println("============");
        boolean ret = myList.contains(55);
        System.out.println(ret);
    }
    public static void main3(String[] args) {
        MyList myList = new MyList();
        myList.addLast(11);
        myList.addLast(22);
        myList.addLast(33);
        myList.display();
        System.out.println("=============");
        myList.clear();
        myList.display();
    }
    public static void main2(String[] args) {
        MyList myList = new MyList();
        myList.addLast(11);
        myList.addLast(22);
        myList.addLast(33);
        myList.addLast(44);
        myList.addLast(55);
        myList.display();
    }
    public static void main1(String[] args) {
        MyList myList = new MyList();
        myList.addFirst(11);
        myList.addFirst(22);
        myList.addFirst(33);
        myList.addFirst(44);
        myList.addFirst(55);
        myList.display();
        int ret = myList.size();
        System.out.println(ret);
    }
}
